<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>新增分类</title>
    <link rel="stylesheet" href="../../font/iconfont.css">
    <link rel="stylesheet" href="../../lib/bootstrap-3.4.1-dist/css/bootstrap.min.css">
    <script src="../../lib/jquery/jquery-3.6.0.js"></script>
    <script src="../../lib/bootstrap-3.4.1-dist/js/bootstrap.min.js"></script>
    <!-- <link rel="stylesheet" href="../../css/shangpinguanli/shangpinliebiao.css"> -->

    <style>
        ul {
            margin: 0px;
            padding: 0px;
        }

        .clear::after {
            clear: both;
            display: block;
            content: "";
        }

        body {
            background-color: #F2F2F2;
        }

        .container {
            width: 1200px;
            height: 725px;
        }

        #backg {
            background-color: white;
            margin-top: 20px;
        }

        /* 新增商品分类 */
        #backg>div:nth-child(1)>div {
            width: 200px;
            height: 60px;
            margin-left: 50px;
            margin-top: 40px;
        }

        #backg>div:nth-child(1)>div>p {
            font-size: 24px;
            font-weight: 400;
        }

        /* 分类名称 */
        #backg>div:nth-child(2)>div,
        #backg>div:nth-child(3)>div,
        #backg>div:nth-child(4)>div,
        #backg>div:nth-child(5)>div,
        #backg>div:nth-child(6)>div,
        #backg>div:nth-child(7)>div,
        #backg>div:nth-child(8)>div {
            margin-right: 20px;
        }

        #backg>div:nth-child(2)>input,
        #backg>div:nth-child(3)>input,
        #backg>div:nth-child(4)>input,
        #backg>div:nth-child(5)>input,
        .shanagpin {
            margin-left: 15px;
            width: 400px;
            height: 45px;
        }

        .anniu1,
        .anniu2 {
            width: 125px;
            height: 45px;
            line-height: 45px;
            text-align: center;
            outline: 1px solid rgb(214, 212, 212);
        }

        .anniu1 {
            background-color: #0099FF;
            color: white;
        }

        .anniu2 {
            margin-left: 30px;
        }

        .anniu2:hover {
            outline: 1px solid #0099FF;
            color: #0099FF;
        }

        .color {
            color: red;
        }

        .hangju {
            margin-top: 20px;
        }

        .text_right {
            text-align: right;
            height: 45px;
            line-height: 45px;
        }

        .icon_anniu {
            position: relative;
        }

        .icon-anniu_kaiqi {
            height: 40px;
            line-height: 40px;
            font-size: 36px;
            color: #0099FF;
            position: absolute;
            top: 5px;
        }

        .icon-anniu_guanbi {
            height: 40px;
            line-height: 40px;
            font-size: 36px;
            color: #CCCCCC;
            position: absolute;
            top: 5px;
            display: none;
        }

        #text_tarea {
            max-width: 400px;
            min-width: 400px;
            max-height: 130px;
            min-height: 130px;
            margin-left: 15px;

        }

        .texe_icon {
            position: relative;
        }

        .shuzi {
            color: rgb(204, 202, 202);
            position: absolute;
            bottom: -120px;
            margin-left: 560px;
        }

        /* 三级下拉 */
        .input-group {
            float: left;
        }

        .content_left {
            margin-left: 20px;
            float: left;
        }

        .content_right {
            float: right;
            margin-right: 60px;
        }

        .content {
            width: 570px;
            height: 190px;
            font-size: 16px;
            position: relative;
            border: 1px solid #CCCCCC;
            position: absolute;
            top: 34px;
            z-index: 999;
            background-color: #FFFFFF;
            display: none;
            cursor: pointer;
            margin-left: 15px;
            margin-top: 11px;
        }

        .content1 {
            width: 400px;
            height: 250px;
            font-size: 16px;
            position: relative;
            border: 1px solid #CCCCCC;
            position: absolute;
            top: 34px;
            left: -415px;
            z-index: 999;
            background-color: #FFFFFF;
            display: none;
            cursor: pointer;
            margin-left: 15px;
            margin-top: 11px;
        }

        .content>ul>li {
            width: 190px;
            height: 45px;
            list-style: none;
        }

        .content1>ul>li {
            width: 400px;
            height: 25px;
            list-style: none;
        }

        .content>ul>li>span>span {
            margin-left: 80px;
            color: #999;
        }

        .content>ul>li>span {
            line-height: 45px;
            margin-left: 20px;
            color: #454545;
        }

        .content1>ul>li>span {
            line-height: 25px;
            margin-left: 20px;
            color: #454545;
        }

        .content>ul,
        .content1>ul {
            position: absolute;
            top: 0;
            left: 0;
            transition: all 1s linear;
        }

        .content>ul>li:hover {
            background-color: #F5F7FA;
            color: #409EFE;
        }

        .content1>ul>li:hover {
            background-color: #409EFE;
        }

        .content1>ul>li:hover span {
            color: white;
        }

        .content>ul>li:hover span {
            background-color: #F5F7FA;
            color: #409EFE;
        }

        .content .two {
            display: none;
            transition: all 1s linear;
        }

        .content .three {
            display: none;
            transition: all 1s linear;
        }

        .tishi {
            color: gray;
            height: 45px;
            line-height: 45px;
        }

        /* .four{
            display: none;
            transition: all 1s linear; 
        } */
        /* 三级下拉箭头 */
        .icon-arrow-down {
            position: absolute;
            top: 10px;
            right: 10px;
            display: block;
        }
        .tijiao_cg{
            width: 85px;
            line-height: 20px;
            outline: 1px solid gray;
        }
        .tijiao_cg button{
            margin: 2px;
        }
    </style>
</head>

<body>
    <div id="backg" class="container">
        <div class="row hangju">
            <div class="col-md-12 col-xs-12">
                <p>新增商品分类</p>
            </div>
        </div>

        <div class="row hangju">
            <div class="col-md-2 col-xs-2 text_right">
                <span class="color">*</span>
                <span>分类名称</span>
            </div>
            <input type="text" class="col-md-4">
        </div>

        <div class="row hangju">
            <div class="col-md-2 col-xs-2 text_right">
                <span class="color">*</span>
                <span>分类编码</span>
            </div>
            <input type="text" class="col-md-4">
        </div>

        <div class="row hangju clear">
            <div class="col-md-2 col-xs-2 text_right">
                <span class="color">*</span>
                <span>上级分类</span>
            </div>

            <!-- 三级下拉 -->
            <div class="input-group">
                <input class="shanagpin col-md-4 col-xs-4" onclick="btnF()" placeholder="请选择分类"><span
                    class="iconfont icon-arrow-down"></span></input>
                <div class="content">
                    <ul class="clear one">
                    </ul>
                    <ul class="clear two">
                    </ul>
                    <ul class="clear three">
                    </ul>
                </div>
            </div>
            <span class="col-md-4 col-xs-4 tishi">提示：不选择上级分类时，默认为一级分类</span>
        </div>
        <div class="row hangju xiala_input">
            <div class="col-md-2 col-xs-2 text_right">
                <span class="color">*</span>
                <span>选择规格</span>
            </div>
            <input type="text" placeholder="请选择商品规格" class="col-md-4 col-xs-4" onclick="arrX()">
            <div class="input-group">
                <div class="content1">
                    <ul class="four">

                    </ul>
                </div>

            </div>
        </div>
        <div class="row hangju">
            <div class="col-md-2 col-xs-2 text_right">
                <p>分类备注</p>
            </div>
            <div class="texe_icon">
                <textarea name="text" id="text_tarea" cols="54" rows="6" class="col-md-4"></textarea>
                <div class="shuzi">0/200</div>
            </div>

        </div>
        <div class="row hangju">
            <div class="col-md-2 col-xs-2 text_right">
                <p>当前状态</p>
            </div>
            <div class="col-md-4 col-xs-4 texe_icon">
                <span class="iconfont icon-anniu_kaiqi"></span>
                <span class="iconfont icon-anniu_guanbi"></span>
            </div>
        </div>
        <div class="row hangju">
            <div class="col-md-2 col-xs-2 anniu_right"></div>
            <div class="col-md-1 col-xs-1">
                <a href="./shangpinfenlei.html"><div class="anniu1" onclick="tijiao()">提交</div></a>
                <!-- <div class="tijiao_cg"></div> -->
            </div>
            <div class="col-md-1 col-xs-1">
                <div class="anniu2">取消</div>
            </div>
        </div>
    </div>

    <script src="../../javaScript/shangpinshuxing/xinzengfenlei.js"></script>
    <script>
        $('.icon-anniu_kaiqi').click(function () {
            $(this).css({
                display: "none",
            })
            $(this).siblings().css({
                display: "block",
            })
        })
        $('.icon-anniu_guanbi').click(function () {
            $(this).css({
                display: "none",
            })
            $(this).siblings().css({
                display: "block",
            })
        })
        $('.anniu1').parent().css({
            color: "black",
            textDecoration: "none"
        })
        // function tijiao() {
        //     $('.tijiao_cg').html(`
        //         <button>提交成功</button>
        //         <button>提交失败</button>  
        //     `)
        //     $('.tijiao_cg button').css({
        //         width:"80px"
        //     })
        // }

    </script>

</body>

</html>